package Projet;

import java.util.*;

public class Lecture {

    int[] permutation;
    int n;

    int[] Permutation(Scanner scanner) {
        if (scanner.hasNextInt()) {
            n = scanner.nextInt();                
            int z, x = 1;
            permutation = new int[n+1];
            for (int i = 0; i < n; i++) {
                if (scanner.hasNextInt()) {
                    z = scanner.nextInt();
                    permutation[x] = z;
                    x++;
                } else {
                    scanner.next();
                    n++;
                }

            }
        }
        return permutation;
    }
}
